Skip to content

PP-4542: 3.2.0 regression test-quality fixes (F-003/F-005/F-006/F-007/F-008)#1052

Merged
mauricecarrier7 merged 6 commits into
developfrom
fix/pp4542-regression-test-coverage
Jun 10, 2026
Merged

PP-4542: 3.2.0 regression test-quality fixes (F-003/F-005/F-006/F-007/F-008)#1052
mauricecarrier7 merged 6 commits into
developfrom
fix/pp4542-regression-test-coverage

Conversation

@mauricecarrier7

Copy link
Copy Markdown
Contributor

Test-quality fixes surfaced by the 3.2.0 pre-release regression (PP-4542) against the release/3.2.0 candidate. Predominantly test additions that kill specific surviving mutants; one behavior-preserving extraction enables the audiobook coverage.

Findings addressed

  • F-003 — BookRegistrySync false-green tests. The PP-4407 awaitReady() migration changed sync() so the no-loansUrl case transitions setState(.syncing) → .loaded instead of being a synchronous no-op. Two baseline tests were band-aided with XCTSkipIf(currentAccount?.loansUrl != nil) — so they skipped on a signed-in CI sim (false green) and failed in a clean env. Replaced the skip-dodge with deterministic fixture-injected tests that assert the real transient-state contract.
  • F-006 — DownloadAuthRetryHandler 33% → 100% kill. Added 401-vs-non-401 discrimination + the no-retry false branch (host-scoped 401 guard: foreign-host short-circuit, same-host positive control, 403 negative).
  • F-007 — AudiobookSessionManager 0% → 88.9% kill. Position-validation / candidate-selection coverage (recency ordering, TOC track-key match, validationFailure guards). Required a behavior-preserving extraction of selectMostRecentValidBookmark(from:in:) + 5 privateinternal seam exposures (no behavior change).
  • F-008 — SAML/browser-auth branch discrimination. Killed the authDef?.isSaml/isBrowserBased == true survivors across BookReturnService / BorrowOperation / TokenRefreshInterceptor with SAML-vs-OAuth discriminating test pairs. Cosmetic/dead/equivalent mutants were deliberately NOT chased (documented).
  • F-005 — palace_mutate skip-rule. Test-environment-detection guard lines (XCTestConfigurationFilePath, etc.) are unkillable by design; now skipped like log lines, so they stop deflating kill rate (TPPReauthenticator was a false 0%).

Verification

  • Consolidated retest on the merged tree: 118 tests, 0 failures, 0 skips (BookRegistrySync now runs without the XCTSkipIf dodge).
  • Diff-only mutation vs origin/release/3.1.0: DownloadAuthRetryHandler 33%→100%, BookReturnService→100%, AudiobookSessionManager 0%→88.9%, TokenRefreshInterceptor/BorrowOperation SAML branches killed.
  • ForgeOS cs_7e7ab728: architect (rev_39f29990) + qa_test (rev_7114cb1a) approved; review/testing/release gates passed.

Notes / follow-ups (not in this PR)

  • F-009 (pre-existing): BookReturnService.swift:235 force-unwraps task! before the Task{} assignment — an IUO-nil race in the return path. Surfaced while writing the return-path tests; needs a separate production fix.
  • QA non-blocking warning: a few async tests use fixed polling loops — prefer condition-await in follow-ups.

Jira: PP-4542

@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

🏗️ CodeAtlas Ledger Analysis

✅ All Checks Passed


♿ Accessibility (via AccessLint)

💡 Static analysis against WCAG 2.1 AA guidelines for iOS accessibility.

No accessibility issues detected


🧪 Test Coverage (via QAAtlas)

⚠️ No coverage data available - QAAtlas requires an OpenAI API key.
Set OPENAI_API_KEY in repository secrets to enable AI-powered test coverage analysis.


🏛️ Architecture Analysis

Metric Value ℹ️ What This Means
Components 22 Distinct modules/layers detected in your codebase
Dependency Cycles 0 Circular dependencies (A→B→C→A). Goal: 0
Layer Violations 1 Dependencies that break architectural boundaries
Hotspots 0 Files with high complexity + frequent changes
Avg Coupling 0.55 How interconnected modules are (lower is better, <1.0 is good)

🔍 Reachability Analysis

💡 Detects code that cannot be reached from entry points (dead code).

No dead code detected


📊 0 files analyzed | 📦 Download Full Report

Powered by CodeAtlas Ledger
• Accessibility: AccessLint

@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

🧪 Unit Test Results

📊 View Full Interactive Report

❌ 1 TEST FAILED

7151 tests | 7047 passed | 1 failed | 103 skipped | ⏱️ 17m 5s | 📊 98.5% | 📈 47.4% coverage

Tests by Class — 822 classes, 1 with failures
Class Tests Passed Failed Duration
✅ AccessLintComplianceTests 11 11 0 23ms
✅ AccessibilityAnnouncementCenterTests 20 20 0 1.63s
✅ AccessibilityLabelTests 9 9 0 31ms
✅ AccessibilityPreferencesTests 26 26 0 224ms
✅ AccessibilityServiceTests 11 11 0 101ms
✅ AccountAuthDocCarryoverTests 5 5 0 1.48s
✅ AccountAuthSurfaceHostsTests 7 7 0 103ms
✅ AccountAwareNetworkTests 10 10 0 264ms
✅ AccountDetailCredentialStateTests 7 0 0 120ms
✅ AccountDetailPINVisibilityTests 25 0 0 538ms
✅ AccountDetailSignOutConfirmationTests 2 0 0 63ms
✅ AccountDetailViewModelGapTests 1 1 0 109ms
✅ AccountDetailViewModelTests 19 0 0 301ms
✅ AccountDetailsAuthenticationIsBrowserBasedTests 10 10 0 84ms
✅ AccountDetailsNeedsAuthAggregateTests 10 10 0 48ms
✅ AccountDetailsURLTests 17 17 0 132ms
✅ AccountModelGapTests 9 9 0 1.82s
✅ AccountModelTests 20 20 0 4.28s
✅ AccountProfileDocumentTests 3 3 0 23ms
✅ AccountStateMachineTests 10 10 0 1.31s
✅ AccountSwitchCleanupTests 8 8 0 310ms
✅ AccountSwitchIntegrationTests 8 8 0 140ms
✅ AccountSwitchLifecycleTests 9 0 0 177ms
✅ AccountsManagerCacheTests 16 16 0 2.91s
✅ AccountsManagerCancellationTests 5 5 0 596ms
✅ AccountsManagerGapTests 3 3 0 19ms
✅ AccountsManagerHelpersTests 12 12 0 31ms
✅ AccountsManagerIsolationLintTests 2 2 0 1.11s
✅ AccountsManagerStateMachineWiringTests 13 13 0 4.53s
✅ AccountsManagerTests 51 50 0 1m 42s
✅ ActiveSessionsViewModelTests 12 12 0 302ms
✅ AdobeActivationTests 6 6 0 32ms
✅ AdobeCertificateGapTests 7 7 0 38ms
✅ AdobeDRMCharacterizationTests 21 21 0 72ms
✅ AdobeDRMErrorGapTests 3 3 0 15ms
✅ AdobeDRMHandlerTests 12 12 0 87ms
✅ AdobeDRMServiceGapTests 2 2 0 5ms
✅ AlertModelCoverageTests 6 6 0 24ms
✅ AlertModelRetryTests 7 7 0 26ms
✅ AlertModelTests 2 2 0 6ms
✅ AlertUtilsTests 20 20 0 1.46s
✅ AnnotationContractTests 3 3 0 31ms
✅ AnnotationDeviceIDTests 2 2 0 16ms
✅ AnnotationPostResponseContractTests 1 1 0 10ms
✅ AnnouncementChainTests 5 5 0 118ms
✅ AnnouncementTests 3 3 0 10ms
✅ AnonymousBorrowBaselineFixtureTests 13 13 0 133ms
✅ AnonymousBorrowCandidateFixtureTests 6 6 0 42ms
✅ AnonymousBorrowDeltaTests 2 2 0 15ms
✅ AppContainerAudiobookFactoryTests 3 3 0 7ms
✅ AppContainerAuthCoordinatorRegistrationTests 3 3 0 7ms
✅ AppContainerImageLoaderInjectionTests 4 4 0 75ms
✅ AppContainerIsolationLintTests 5 5 0 2.00s
✅ AppContainerResetTests 4 4 0 64ms
✅ AppContainerTests 4 4 0 19ms
✅ AppContainerWithSignInModalSheetPresenterTests 2 2 0 15ms
✅ AppHealthViewModelTests 8 8 0 1.39s
✅ AppLaunchTrackerExtendedTests 16 16 0 437ms
✅ AppLaunchTrackerTests 10 10 0 391ms
✅ AppRouteTests 5 5 0 20ms
✅ AppTabHostMiniPlayerIntegrationTests 6 6 0 379ms
✅ AppTabHostViewBadgeCountTests 10 10 0 116ms
✅ AppTabRouterCoverageTests 4 4 0 14ms
✅ AppTabRouterGapTests 3 3 0 12ms
✅ ArrayExtensionsTests 6 6 0 22ms
✅ AudioBookmarkGapTests 6 6 0 567ms
✅ AudioEngineWrapperTests 8 8 0 213ms
✅ AudioInterruptionLogicTests 6 6 0 39ms
✅ AudiobookAccessibilityTests 7 7 0 56ms
✅ AudiobookBackgroundAudioTests 2 2 0 41ms
✅ AudiobookBookmarkBusinessLogicPositionWriteTests 6 6 0 1m 11s
✅ AudiobookBookmarkBusinessLogicTests 21 21 0 4.23s
✅ AudiobookChapterTOCNormalizationTests 6 6 0 17ms
✅ AudiobookCrossVendorSmokeTests 4 4 0 143ms
✅ AudiobookDataManagerEmptyQueueTests 1 1 0 13ms
✅ AudiobookDataManagerErrorHandlingTests 5 5 0 10.40s
✅ AudiobookDataManagerModelsTests 20 20 0 107ms
✅ AudiobookDataManagerNetworkSyncTests 5 5 0 5.22s
✅ AudiobookDataManagerSaveTests 4 4 0 75ms
✅ AudiobookDataManagerStoreRecoveryTests 5 5 0 2.38s
✅ AudiobookFileLoggerTests 14 14 0 438ms
✅ AudiobookFirstOpenHangTests 5 5 0 5.38s
✅ AudiobookFullPlayerCoverContainerTests 9 9 0 174ms
✅ AudiobookLoadFailureSAMLReauthTests 10 10 0 862ms
✅ AudiobookLoaderDispatchTests 7 7 0 313ms
✅ AudiobookLoaderFinalizeBuildTests 9 9 0 369ms
✅ AudiobookLoaderOPDSShapeMatrixTests 5 5 0 171ms
✅ AudiobookLoaderPredicateTests 11 11 0 95ms
✅ AudiobookLoaderTests 2 2 0 179ms
✅ AudiobookMiniPlayerViewTests 13 13 0 182ms
✅ AudiobookNetworkValidationTests 3 3 0 20ms
✅ AudiobookOpenStateRaceTests 3 3 0 557ms
✅ AudiobookPhoneAlertContentTests 3 3 0 29ms
✅ AudiobookPlaybackStateTests 3 3 0 84ms
✅ AudiobookPlaybackTests 26 26 0 496ms
✅ AudiobookPlaytimesLifecycleTests 6 6 0 1.96s
✅ AudiobookPositionAdapterContractTests 3 3 0 136ms
✅ AudiobookPositionPolicyValidatorTests 14 14 0 24ms
✅ AudiobookPositionRestoreTests 11 11 0 1.56s
✅ AudiobookSAMLReauthTests 6 6 0 108ms
✅ AudiobookSessionErrorDescriptionTests 4 4 0 16ms
✅ AudiobookSessionErrorExtTests 4 4 0 19ms
✅ AudiobookSessionErrorTests 2 2 0 8ms
✅ AudiobookSessionManagerErrorMappingTests 6 6 0 24ms
✅ AudiobookSessionManagerFlagGatePresentationTests 4 4 0 6.20s
✅ AudiobookSessionManagerPresenterMigrationTests 8 8 0 2.96s
✅ AudiobookSessionManagerShutdownTests 8 8 0 207ms
✅ AudiobookSessionPresenterTests 16 16 0 815ms
✅ AudiobookSessionStateTests 6 6 0 57ms
✅ AudiobookSessionStateTransitionTests 18 18 0 49.62s
✅ AudiobookSleepTimerIntegrationTests 5 5 0 466ms
✅ AudiobookStorageLocationTests 3 3 0 11ms
✅ AudiobookTOCTests 18 18 0 2.57s
✅ AudiobookTimeEntryTests 6 6 0 24ms
✅ AudiobookTimeTrackerEdgeTests 8 8 0 148ms
✅ AudiobookTimeTrackerLifecycleTests 5 5 0 1.09s
✅ AudiobookTimeTrackerTests 9 9 0 163ms
✅ AudiobookTrackCompletionTests 2 2 0 45ms
✅ AudiobookTypeRoutingTests 5 5 0 870ms
✅ AudiobookVendorAdapterTests 5 5 0 48ms
✅ AudiobookmarkTests 4 4 0 25ms
✅ AuthCoordinatorTelemetryTests 5 5 0 68ms
✅ AuthDecisionEventEmissionTests 7 7 0 49ms
✅ AuthDocumentContractTests 2 2 0 39ms
✅ AuthDocumentVariantsContractTests 5 5 0 30ms
✅ AuthErrorCategoryTests 12 12 0 39ms
✅ AuthErrorProblemDocSeamTests 6 6 0 40ms
✅ AuthFlowSecurityTests 3 0 0 392ms
✅ AuthReducerTests 21 21 0 103ms
✅ AuthTypeTests 7 7 0 48ms
✅ AuthenticationTests 16 16 0 4.12s
✅ BackgroundDownloadHandlerTests 28 28 0 228ms
✅ BackgroundListenerTests 2 2 0 96ms
✅ BackupExclusionMigrationTests 3 3 0 27ms
✅ BadgeDefinitionTests 33 33 0 271ms
✅ BadgeServiceTests 16 16 0 301ms
✅ BadgesViewModelTests 14 14 0 323ms
✅ BasicAuthEmptyCredentialTests 4 4 0 11ms
✅ BearerTokenAdapterTests 5 4 0 67ms
✅ BearerTokenFulfillFlowTests 4 4 0 39ms
✅ BearerTokenRefreshTests 4 4 0 391ms
✅ BearerTokenResponseDetectionTests 7 7 0 43ms
✅ BeginningPositionPolicyTests 8 8 0 467ms
✅ BookAvailabilityFormatterTests 18 18 0 76ms
✅ BookButtonMapperHoldReadyTests 10 10 0 31ms
✅ BookButtonMapperTests 21 21 0 118ms
✅ BookButtonMapperViewModelTests 18 18 0 70ms
✅ BookButtonStateTests 8 8 0 83ms
✅ BookButtonTypeMetaTests 4 4 0 35ms
✅ BookButtonTypeTests 13 13 0 100ms
✅ BookCellModelActionTests 18 18 0 811ms
✅ BookCellModelCacheInvalidationTests 8 8 0 96ms
✅ BookCellModelCachePrefetchSafetyTests 9 9 0 485ms
✅ BookCellModelCacheTests 22 22 0 30.11s
✅ BookCellModelComputedPropertyTests 19 19 0 500ms
✅ BookCellModelOfflineTests 9 9 0 421ms
✅ BookCellModelRegistryBindingTests 4 4 0 354ms
✅ BookCellModelStateTests 16 16 0 413ms
✅ BookCellModelStreamingHTMLTests 2 2 0 135ms
✅ BookCellStateComprehensiveTests 14 14 0 365ms
✅ BookContentResetServiceTests 2 2 0 44ms
✅ BookDetailMetadataHydrationTests 6 6 0 8.66s
✅ BookDetailViewModelTests 87 87 0 1.65s
✅ BookFileManagerTests 8 8 0 59ms
✅ BookListViewAccessibilityTests 9 9 0 61ms
✅ BookPreviewTests 4 4 0 19ms
✅ BookRegistryStoreTests 26 26 0 914ms
✅ BookRegistrySyncReadinessTests 3 2 0 619ms
✅ BookRegistrySyncTests 24 22 0 397ms
✅ BookReturnCleverReauthTests 1 1 0 18ms
✅ BookReturnServiceAuthCoordinatorTests 3 3 0 927ms
✅ BookReturnServiceContractTests 5 5 0 5.10s
✅ BookReturnServiceTests 14 14 0 901ms
✅ BookSignInRedirectHandlerTests 8 8 0 288ms
✅ BookStateIntegrationTests 8 8 0 75ms
✅ BookmarkBusinessLogicExtendedTests 6 6 0 778ms
✅ BookmarkDeletionLogTests 3 3 0 640ms
✅ BookmarkDeviceIdMatchingTests 3 3 0 294ms
✅ BookmarkExistenceTests 4 4 0 422ms
✅ BookmarkManagerTests 24 24 0 706ms
✅ BookmarkSortingTests 1 1 0 192ms
✅ BookmarkSyncTests 3 3 0 318ms
✅ BorrowAndDownloadIntegrationTests 7 7 0 322ms
✅ BorrowErrorMessageTests 13 13 0 77ms
✅ BorrowErrorPresenterTests 6 6 0 535ms
✅ BorrowOperationAuthCoordinatorTests 6 6 0 7.22s
✅ BorrowOperationCleverReauthTests 2 2 0 347ms
✅ BorrowOperationContractTests 6 6 0 511ms
✅ BorrowOperationStreamingHTMLTests 3 3 0 1.55s
✅ BorrowOperationTests 13 13 0 2.03s
✅ BorrowOperationTimeoutTests 3 3 0 159ms
✅ BorrowReducerContractTests 2 2 0 20ms
✅ BorrowReducerTests 21 21 0 126ms
✅ BundledRegistrySnapshotTests 5 5 0 625ms
✅ ButtonStateTests 16 16 0 407ms
✅ ButtonStyleTypeTests 2 2 0 6ms
✅ C64ConversionTests 6 6 0 21ms
✅ CarPlayAudiobookBridgePresenterMigrationTests 2 2 0 216ms
✅ CarPlayAuthHelperReadinessTests 3 3 0 1.19s
✅ CarPlayChapterListTests 3 3 0 20ms
✅ CarPlayIntegrationTests 2 2 0 15ms
✅ CarPlayLibraryRefreshTests 3 3 0 18ms
✅ CarPlayNowPlayingTemplateTests 4 4 0 529ms
✅ CarPlayOpenAppAlertTests 4 4 0 12ms
✅ CarPlayPlaybackErrorTests 8 8 0 33ms
✅ CarPlayTests 12 12 0 1.92s
✅ CarPlayTimeTrackingTests 3 3 0 112ms
✅ CatalogAPIDedupeTests 3 3 0 449ms
✅ CatalogAPIEntryPointTests 1 1 0 16ms
✅ CatalogAccessibilityTests 8 8 0 21ms
✅ CatalogCacheKeyAndIsolationTests 12 12 0 258ms
✅ CatalogCacheMetadataExactBoundaryTests 4 4 0 25ms
✅ CatalogCacheMetadataTests 21 21 0 76ms
✅ CatalogFeedModelTests 4 4 0 103ms
✅ CatalogFilterGroupModelTests 17 17 0 147ms
✅ CatalogFilterModelTests 17 17 0 36ms
✅ CatalogFilterServiceTests 29 29 0 88ms
✅ CatalogFilterTests 1 1 0 3ms
✅ CatalogLaneAssemblyTests 7 7 0 20ms
✅ CatalogLaneModelStructTests 18 18 0 1.34s
✅ CatalogLaneModelTests 1 1 0 3ms
✅ CatalogLaneMoreFilterStateTests 8 8 0 87ms
✅ CatalogLaneMoreViewModelTests 42 42 0 776ms
✅ CatalogLaneRowViewAccessibilityTests 11 11 0 1.17s
✅ CatalogLaneSortingTests 4 4 0 97ms
✅ CatalogLoadIntegrationTests 6 6 0 60ms
✅ CatalogOPDS2NegotiationTests 12 12 0 94ms
✅ CatalogPreloaderTests 6 6 0 74ms
✅ CatalogProblemDocumentTests 6 6 0 121ms
✅ CatalogRepositoryCoreTests 9 9 0 349ms
✅ CatalogRepositoryStaleWhileRevalidateTests 12 12 0 467ms
✅ CatalogRepositoryTests 19 19 0 260ms
✅ CatalogSearchViewModelRegistryUpdateTests 5 5 0 210ms
✅ CatalogSearchViewModelTests 67 67 0 7.56s
✅ CatalogSelectorsTests 2 2 0 16ms
✅ CatalogSortServiceTests 14 14 0 143ms
✅ CatalogStateTests 7 7 0 66ms
✅ CatalogViewContinueRowsIntegrationTests 3 3 0 32ms
✅ CatalogViewModelStateMachineTests 10 10 0 109ms
✅ ChaosFaultInjectionTests 5 5 0 53ms
✅ ChapterChangeDetectorTests 5 5 0 62ms
✅ ChapterTOCNormalizerTests 7 7 0 49ms
✅ CirculationAnalyticsTests 4 4 0 41ms
✅ ColdStartResumeIntegrationTests 10 10 0 1.05s
✅ ColorExtensionTests 5 5 0 27ms
✅ ConcurrentBookStateTests 3 3 0 64ms
✅ ConcurrentDownloadStateTests 3 3 0 65ms
✅ ConcurrentTokenRefreshTests 2 2 0 97ms
✅ ContinueRowSectionTests 6 6 0 60ms
✅ ContinuousPlaybackTrackingTests 3 3 0 921ms
✅ CookiePersistenceTests 10 10 0 965ms
✅ CrawlStateTests 16 16 0 62ms
✅ CrawlableFeedAnalysisTests 17 17 0 119ms
✅ CrawlerFallbackTests 12 12 0 766ms
✅ CredentialEdgeCaseTests 6 6 0 17ms
✅ CredentialPrivacyTests 4 4 0 19ms
✅ CredentialPromptCoordinatorTests 4 4 0 368ms
✅ CrossDeviceBookmarkSyncTests 12 12 0 106ms
✅ CrossDeviceSyncE2ETests 5 5 0 1.76s
✅ CrossDomain401Tests 8 8 0 25ms
✅ CrossFormatMappingTests 14 14 0 52ms
✅ DPLAErrorTests 3 3 0 12ms
✅ DRMAdversarialTests 4 1 0 153ms
✅ DRMFulfilledPublicationTests 6 6 0 34ms
✅ DataBase64Tests 3 3 0 14ms
✅ DataReceptionComparisonTests 2 2 0 53ms
✅ DateExtensionTests 9 9 0 26ms
✅ DateFormattingTests 4 4 0 17ms
✅ Date_NYPLAdditionsTests 7 7 0 520ms
✅ DebugSettingsTests 27 27 0 167ms
✅ DefaultCatalogAPITests 31 31 0 366ms
✅ DefaultRecentlyReadingServiceTests 12 12 0 87ms
✅ DeriveInitialStateTests 4 4 0 52ms
✅ DeveloperSettingsTierTests 4 4 0 23ms
✅ DeviceLogCollectorGapTests 2 2 0 12.77s
✅ DeviceLogCollectorTests 9 9 0 47.85s
✅ DeviceOrientationTests 7 7 0 29ms
✅ DeviceSpecificErrorMonitorTests 11 11 0 219ms
✅ DictionaryExtensionsTests 5 5 0 23ms
✅ DiskBudgetManagerTests 7 7 0 35ms
✅ DiskBudgetTests 2 2 0 22ms
✅ DownloadAlertPresenterTests 8 8 0 767ms
✅ DownloadAnnouncementServiceTests 12 12 0 135ms
✅ DownloadAuthRetryHandlerAuthCoordinatorTests 6 6 0 2.64s
✅ DownloadAuthRetryHandlerTaskLifecycleTests 4 4 0 401ms
✅ DownloadAuthRetryHandlerTests 17 17 0 2.49s
✅ DownloadCancellationHandlerTests 5 5 0 297ms
✅ DownloadCompletionParserTests 9 9 0 184ms
✅ DownloadCoordinatorIntegrationTests 10 10 0 1.07s
✅ DownloadCoordinatorTests 11 11 0 529ms
✅ DownloadDiskSpaceTests 2 2 0 10ms
✅ DownloadErrorInfoTests 3 3 0 50ms
✅ DownloadErrorRecoveryPolicyTests 11 11 0 164ms
✅ DownloadErrorRecoveryTests 3 3 0 27ms
✅ DownloadFreeSpaceExhaustionTests 11 11 0 85ms
✅ DownloadInfoTests 5 5 0 20ms
✅ DownloadIntegrityTests 10 10 0 228ms
✅ DownloadOnlyOnWiFiTests 10 10 0 77ms
✅ DownloadPersistenceStoreTests 5 5 0 58ms
✅ DownloadProgressPublisherCoreTests 19 19 0 732ms
✅ DownloadProgressPublisherTests 2 2 0 14ms
✅ DownloadQueueIntegrationTests 3 3 0 73ms
✅ DownloadQueueOrchestratorTests 9 9 0 481ms
✅ DownloadRMSDKHandoffTests 1 1 0 2ms
✅ DownloadRedirectTests 7 7 0 24ms
✅ DownloadResumeAfterKillTests 7 7 0 160ms
✅ DownloadSlotManagementTests 5 5 0 2.37s
✅ DownloadStartCoordinatorContractTests 5 5 0 129ms
✅ DownloadStartCoordinatorTests 9 9 0 274ms
✅ DownloadStartDispatcherTests 26 26 0 675ms
✅ DownloadStateMachineIntegrationTests 15 15 0 164ms
✅ DownloadStateMachineTests 5 5 0 30ms
✅ DownloadStateManagerTests 16 16 0 151ms
✅ DownloadTaskLifecycleServiceTests 9 9 0 2.38s
✅ DownloadThrottlingServiceTests 10 10 0 478ms
✅ DownloadWatchdogTests 3 3 0 200ms
✅ EPUBKeyCommandsPP4289Tests 4 4 0 53ms
✅ EPUBModuleTests 4 4 0 43ms
✅ EPUBPositionTests 10 10 0 171ms
✅ EPUBSearchViewModelTests 18 18 0 165ms
✅ EPUBToolbarToggleTests 11 11 0 87ms
✅ EmailAddressTests 16 16 0 123ms
✅ EpubSampleFactoryTests 5 5 0 27ms
✅ ErrorActivityTrackerTests 12 12 0 76ms
✅ ErrorDetailTests 12 12 0 125ms
✅ ErrorDetailViewControllerGapTests 3 3 0 227ms
✅ ErrorDetailViewControllerTests 14 14 0 119ms
✅ ErrorLogExporterTests 5 5 0 101ms
✅ ExpiredLoanStringsTests 5 5 0 1.58s
✅ FacetEnumTests 3 3 0 10ms
✅ FacetToolbarAccessibilityTests 5 5 0 23ms
✅ FacetViewModelLogoDelegateTests 4 4 0 23ms
✅ FacetViewModelTests 18 18 0 15.11s
✅ FetchManifestWithBearerTokenLCPSafetyTests 1 1 0 41ms
✅ FetchManifestWithBearerTokenTests 9 9 0 158ms
✅ FetchOpenAccessManifestLCPSafetyTests 4 4 0 17ms
✅ FileURLGenerationTests 3 3 0 30ms
✅ FindawayChapterStatusGuardTests 1 1 0 16ms
✅ FloatTPPAdditionsTests 5 5 0 25ms
✅ FocusIndicationTests 7 7 0 69ms
✅ FontManagerTests 17 17 0 130ms
✅ ForceResetTests 6 6 0 67ms
✅ GeneralCacheTests 20 20 0 320ms
✅ GroupEnumTests 1 1 0 29ms
✅ HTMLTextViewTests 70 70 0 28.89s
✅ HoldNotificationClassificationTests 2 2 0 7ms
✅ HoldsBadgeCountTests 9 9 0 58ms
✅ HoldsBookViewModelTests 8 8 0 192ms
✅ HoldsReducerTests 11 11 0 202ms
✅ HoldsSyncFailureTests 12 12 0 569ms
✅ HoldsViewModelTests 23 23 0 1.30s
✅ ImageCacheContinuationTests 1 1 0 242ms
✅ ImageCacheTypeTests 1 1 0 4ms
✅ ImageLoaderTests 11 11 0 211ms
✅ IntExtensionsTests 4 4 0 40ms
✅ IsReaderActiveTrackingModifierTests 4 4 0 589ms
✅ KeyboardNavigationFKATests 11 11 0 114ms
✅ KeyboardNavigationHandlerTests 16 16 0 114ms
✅ KeyboardVoiceOverTests 5 5 0 30ms
✅ LCPAcquisitionPredicateTests 4 4 0 24ms
✅ LCPAdapterTests 8 8 0 118ms
✅ LCPAudiobookURLSchemeTests 4 4 0 11ms
✅ LCPAudiobooksTests 21 21 0 145ms
✅ LCPBotanCRLGuardTests 5 5 0 62ms
✅ LCPCharacterizationTests 31 31 0 193ms
✅ LCPClientTests 8 8 0 45ms
✅ LCPFulfillmentHandlerTests 8 8 0 749ms
✅ LCPKeychainMigrationTests 3 3 0 50ms
✅ LCPLibraryServiceTests 20 20 0 225ms
✅ LCPLicenseDocumentDetectionTests 5 5 0 20ms
✅ LCPLicenseFilePathTests 3 3 0 16ms
✅ LCPOrphanedDownloadRegistryTests 4 4 0 36ms
✅ LCPPDFAcquisitionPredicateTests 5 5 0 19ms
✅ LCPPDFDiskExtractTests 5 5 0 89ms
✅ LCPPDFOpenProgressTests 13 13 0 281ms
✅ LCPPassphraseReadinessTests 2 2 0 12ms
✅ LCPSessionIdentifierTests 3 3 0 33ms
✅ LegacySAMLProblemDocumentPropagationTests 7 7 0 1.05s
✅ LibrariesSectionViewModelTests 11 11 0 50ms
✅ LibraryCatalogMergerTests 9 9 0 84ms
✅ LibraryRegistryCrawlerTests 14 14 0 153ms
✅ LicensesServiceTests 4 4 0 19ms
✅ LiveCrawlableParsingTest 4 0 0 28ms
✅ LocalBookContentServiceTests 7 7 0 221ms
✅ LocalFileAdapterTests 6 5 0 85ms
✅ LogTests 14 14 0 388ms
✅ LoginKeyboardTests 8 8 0 148ms
✅ MainActorHelpersTests 22 22 0 693ms
✅ MappedCatalogBridgeTests 3 3 0 28ms
✅ MappedCatalogModelTests 11 11 0 591ms
✅ MockBackendExpiredCredentialsTests 3 3 0 330ms
✅ MockBackendIntegrationTests 4 4 0 271ms
✅ MockBackendLoanLimitTests 2 2 0 111ms
✅ MockBackendRouteMatchingTests 4 4 0 27ms
✅ MockBackendServerDownTests 1 1 0 25ms
✅ MockIsolationLintTests 5 5 0 2.24s
✅ MultiLibraryTokenIsolationTests 14 14 0 453ms
✅ MyBooksDownloadCenterAccountIdThreadingTests 6 6 0 115ms
✅ MyBooksDownloadCenterAdeptGapTests 3 3 0 14ms
✅ MyBooksDownloadCenterConcurrencyTests 21 21 0 530ms
✅ MyBooksDownloadCenterEvictionTests 7 7 0 149ms
✅ MyBooksDownloadCenterOfflineTests 8 8 0 732ms
✅ MyBooksDownloadSessionInvalidationTests 3 3 0 18ms
✅ MyBooksSimplifiedBearerTokenTests 17 17 0 164ms
✅ MyBooksViewModelBooksPublisherTests 3 3 0 32ms
✅ MyBooksViewModelConcurrencyTests 4 4 0 225ms
✅ MyBooksViewModelDownloadStateTests 3 3 0 22ms
✅ MyBooksViewModelEmptyArrayTests 3 3 0 13ms
✅ MyBooksViewModelEmptyStateTests 4 4 0 37ms
✅ MyBooksViewModelExtendedTests 15 15 0 24.78s
✅ MyBooksViewModelFacetIntegrationTests 4 4 0 18ms
✅ MyBooksViewModelFacetPublisherTests 3 3 0 31ms
✅ MyBooksViewModelFilterSortInteractionTests 2 2 0 59ms
✅ MyBooksViewModelFilterTests 9 9 0 185ms
✅ MyBooksViewModelGuardConditionsTests 2 2 0 34ms
✅ MyBooksViewModelLargeDatasetTests 2 2 0 331ms
✅ MyBooksViewModelLoadAccountTests 2 2 0 245ms
✅ MyBooksViewModelLoginStateTests 4 4 0 4.79s
✅ MyBooksViewModelMultipleAuthorSortingTests 3 3 0 42ms
✅ MyBooksViewModelNotificationTests 4 4 0 356ms
✅ MyBooksViewModelOfflineFilteringTests 3 3 0 122ms
✅ MyBooksViewModelPublisherTests 7 7 0 136ms
✅ MyBooksViewModelSearchEdgeCaseTests 6 6 0 85ms
✅ MyBooksViewModelSearchQueryTests 3 3 0 68ms
✅ MyBooksViewModelSortPersistenceTests 3 3 0 2.96s
✅ MyBooksViewModelSortingIntegrationTests 5 5 0 355ms
✅ MyBooksViewModelSortingTests 6 6 0 79ms
✅ MyBooksViewModelStateTransitionTests 3 3 0 410ms
✅ MyBooksViewModelUIBindingTests 3 3 0 28ms
✅ NSErrorAdditionsTests 7 7 0 51ms
✅ NSNotificationTPPTests 3 3 0 49ms
✅ NavigationCoordinatorTests 17 17 0 45ms
✅ NavigationFreezePreventionTests 5 5 0 12ms
✅ NetworkExecutorCredentialGuardTests 8 8 0 343ms
✅ NetworkExecutorResponseRegressionTests 4 4 0 256ms
✅ NetworkExecutorTaskTypeTests 3 3 0 55ms
✅ NetworkOfflineDetectionTests 3 3 0 10ms
✅ NetworkQueueTests 11 11 0 123ms
✅ NetworkRequestQueueTests 2 2 0 10.23s
✅ NetworkRetryLogicTests 7 7 0 496ms
✅ NetworkTimeoutTests 2 2 0 4ms
✅ NotificationEventTypeContractTests 7 7 0 29ms
✅ NotificationPayloadContractTests 10 10 0 58ms
✅ NotificationServiceStateMachineTests 9 9 0 1.59s
✅ NotificationServiceTests 16 16 0 83ms
✅ NotificationServiceTokenTests 13 13 0 46ms
✅ NotificationSyncThrottleTests 5 5 0 12ms
✅ NotificationTokenDataTests 4 4 0 12ms
✅ NotificationTokenRegistrationTests 10 10 0 95ms
✅ NowPlayingCoordinatorBackgroundTests 6 6 0 475ms
✅ NowPlayingCoordinatorTests 19 19 0 368ms
✅ OAuthSAMLRedirectRegressionTests 4 4 0 489ms
✅ OIDCAuthDocumentParsingTests 4 4 0 262ms
✅ OIDCAuthTypeTests 5 5 0 25ms
✅ OIDCAuthenticationPropertyTests 8 8 0 978ms
✅ OIDCCallbackEdgeCaseTests 9 9 0 1.01s
✅ OIDCCallbackHandlingTests 5 5 0 6.47s
✅ OIDCCallbackSchemeTests 3 3 0 8ms
✅ OIDCIsolationRegressionTests 6 6 0 576ms
✅ OIDCLoginRoutingTests 3 3 0 474ms
✅ OIDCMakeRequestTests 3 3 0 247ms
✅ OIDCNSCodingTests 1 1 0 132ms
✅ OIDCNetworkLayer401Tests 5 5 0 455ms
✅ OIDCReauthOnExpiredTokenTests 5 5 0 906ms
✅ OIDCRedirectURIConstructionTests 6 6 0 726ms
✅ OIDCRegressionTests 9 9 0 1.32s
✅ OIDCSelectedAuthenticationTests 2 2 0 296ms
✅ OIDCSignOutRegressionTests 6 6 0 784ms
✅ OIDCTokenRefreshRegressionTests 6 6 0 684ms
✅ OIDCUpdateUserAccountTests 5 5 0 550ms
✅ OIDCViewModelRegressionTests 1 1 0 161ms
✅ OIDCViewModelSignInTests 2 2 0 53ms
✅ OPDS1BorrowEntryContractTests 4 4 0 70ms
✅ OPDS1CatalogGroupedContractTests 3 3 0 36ms
✅ OPDS1HoldEntriesContractTests 4 4 0 52ms
✅ OPDS1LoansFeedContractTests 6 6 0 118ms
✅ OPDS1ParsingTests 34 34 0 332ms
✅ OPDS1RevokeResponseContractTests 2 2 0 12ms
✅ OPDS2AuthenticationDocumentTests 18 18 0 126ms
✅ OPDS2AvailabilityTests 4 4 0 380ms
✅ OPDS2BookBridgeTests 44 44 0 357ms
✅ OPDS2BorrowResponseContractTests 3 3 0 11ms
✅ OPDS2CatalogWiringTests 17 17 0 160ms
✅ OPDS2CatalogsFeedTests 3 3 0 389ms
✅ OPDS2ContributorTests 2 2 0 31ms
✅ OPDS2EmptyFeedContractTests 1 1 0 10ms
✅ OPDS2FeedContractTests 4 4 0 37ms
✅ OPDS2FeedParsingTests 11 11 0 738ms
✅ OPDS2FeedTests 13 13 0 97ms
✅ OPDS2FullMetadataTests 4 4 0 18ms
✅ OPDS2FullPublicationTests 13 13 0 35ms
✅ OPDS2IntegrationTests 18 18 0 252ms
✅ OPDS2LinkArrayTests 5 5 0 222ms
✅ OPDS2LinkComputedPropertyTests 20 20 0 59ms
✅ OPDS2LinkRelTests 1 1 0 6ms
✅ OPDS2LinkTests 2 2 0 175ms
✅ OPDS2ParsingTests 38 38 0 383ms
✅ OPDS2PublicationExtendedTests 53 53 0 161ms
✅ OPDS2PublicationImageTests 6 6 0 24ms
✅ OPDS2PublicationNarratorTests 3 3 0 2.21s
✅ OPDS2PublicationTests 2 2 0 185ms
✅ OPDS2SamlIDPTests 6 6 0 52ms
✅ OPDS2SearchResultsContractTests 3 3 0 28ms
✅ OPDS2SubjectTests 2 2 0 9ms
✅ OPDS2SupportingTypesTests 5 5 0 36ms
✅ OPDSAcquisitionPathExpandedTests 15 15 0 513ms
✅ OPDSFeedCacheTests 14 14 0 215ms
✅ OPDSFeedMigrationTests 11 11 0 25ms
✅ OPDSFeedParsingTests 2 2 0 281ms
✅ OPDSFeedServiceStateMachineTests 3 3 0 628ms
✅ OPDSFeedServiceTests 2 2 0 10ms
✅ OPDSFormatTests 13 13 0 527ms
✅ OPDSParserCoreTests 4 4 0 13ms
✅ OPDSParserTests 4 4 0 42ms
✅ OPDSParsingTests 57 57 0 5.84s
✅ OfflineActionTests 29 29 0 481ms
✅ OfflineQueueServiceExtendedTests 13 13 0 5.41s
✅ OfflineQueueServiceTests 17 17 0 7.15s
✅ OpenAccessAdapterTests 6 6 0 4.08s
✅ OverdriveDeferredFulfillmentTests 6 6 0 21ms
✅ OverdriveDownloadHandlerTests 9 9 0 244ms
✅ OverdriveFulfillmentTests 5 5 0 104ms
✅ PDFExtensionsTests 20 20 0 114ms
✅ PDFReaderTests 12 12 0 52ms
✅ PP3596RegressionTests 3 3 0 98ms
✅ Palace 2 2 0 <1ms
✅ PalaceCheckPropertyTests 8 8 0 159ms
✅ PalaceErrorCategoryTests 20 20 0 60ms
✅ PalaceErrorExtendedTests 23 23 0 357ms
✅ PalaceErrorTests 11 11 0 377ms
✅ PalacePDFViewTests 12 12 0 225ms
✅ PalaceTestSetupObservationTests 4 4 0 19ms
✅ PalaceWiringTestCaseTests 4 4 0 36ms
✅ ParserFuzzTests 4 4 0 51.16s
✅ PatronProfileContractTests 4 4 0 77ms
✅ PerformanceMonitorTests 14 14 0 152ms
✅ PerformanceReportTests 14 14 0 70ms
✅ PersistentLoggerTests 9 9 0 2.26s
✅ PlaybackBootstrapperTests 8 8 0 600ms
✅ PlaybackFailureRecordTests 5 5 0 11ms
✅ PlaybackOpenPolicyTests 7 7 0 15ms
✅ PlaybackRateTests 16 16 0 60ms
✅ PlaybackTrackingRegressionTests 5 5 0 128ms
✅ PositionPersistenceLogicTests 6 6 0 23ms
✅ PositionPersistenceTests 2 2 0 6ms
✅ PositionSyncServiceTests 13 13 0 556ms
✅ PositionSyncTests 5 5 0 73ms
✅ PositionWriterContractTests 6 6 0 85ms
✅ PostUpdateMigrationTests 5 5 0 64ms
✅ ProblemDocumentContractTests 4 4 0 22ms
✅ ProblemDocumentLoanExpiryTests 5 5 0 18ms
✅ ProblemDocumentTests 12 12 0 84ms
✅ ProblemReportEmailTests 8 8 0 28ms
✅ ReachabilityTests 10 10 0 40ms
✅ Reader2BookmarkContractTests 3 3 0 36ms
✅ Reader2PositionAdapterContractTests 4 3 0 1.73s
✅ Reader2PositionResumeContractTests 3 3 0 414ms
✅ ReaderAccessibilityTests 7 7 0 34ms
✅ ReaderEditingActionsTests 5 5 0 27ms
✅ ReaderErrorTests 5 5 0 61ms
✅ ReaderNavBarVoiceOverTests 2 2 0 16ms
✅ ReaderServiceSyncTests 3 3 0 51ms
✅ ReaderThemeTests 24 24 0 233ms
✅ ReadingPositionTests 22 22 0 458ms
✅ ReadingSessionTrackerTests 13 13 0 350ms
✅ ReadingStatsServiceTests 12 12 0 242ms
✅ ReadingStatsStoreTests 9 9 0 120ms
✅ RedirectHandlingIntegrationTests 4 4 0 11ms
✅ RedirectPolicyTests 9 9 0 128ms
✅ RemoteFeatureFlagsGapTests 4 4 0 42ms
✅ RemoteFeatureFlagsTests 9 9 0 43ms
✅ ResourcePropertiesLengthTests 3 3 0 8ms
✅ RetryClassificationTests 17 17 0 37ms
✅ ReturnFlowTests 1 1 0 25ms
✅ RightsManagementDetectionTests 5 5 0 338ms
✅ RightsManagementDispatcherTests 10 10 0 92ms
✅ SAMLCookieSyncTests 5 5 0 15ms
✅ SAMLLogoutCallbackDetectionTests 4 4 0 25ms
✅ SAMLLogoutLinkParsingTests 5 5 0 108ms
✅ SAMLLogoutURLTests 4 4 0 13ms
✅ SAMLPlusBiblioBoardExpirationTests 8 8 0 1.29s
✅ SEMigrationsTests 6 6 0 123ms
✅ SafeDictionaryTests 21 21 0 295ms
✅ SamplePlayerErrorTests 5 5 0 19ms
✅ SampleTypeTests 8 8 0 78ms
✅ SceneDelegateTests 1 1 0 6ms
✅ ScopedResetTests 9 9 0 376ms
✅ SearchAccessibilityTests 6 6 0 34ms
✅ SearchFlowIntegrationTests 8 8 0 145ms
✅ SettingsViewModelComputedPropertyTests 6 6 0 45ms
✅ SettingsViewModelEdgeCaseTests 7 7 0 7.38s
✅ SettingsViewModelGapTests 1 1 0 27ms
✅ SettingsViewModelSyncTests 14 14 0 4.79s
✅ SettingsViewModelTests 33 33 0 1.30s
✅ SignInModalLifecycleTests 9 9 0 11.10s
✅ SignInModalPredicateTests 3 3 0 10ms
✅ SignInModalSAMLOIDCTests 6 6 0 21ms
✅ SignInOAuthErrorPropagationTests 8 8 0 784ms
✅ SignInToReadFlowIntegrationTests 5 5 0 640ms
✅ SignInWebSheetIntegrationTests 3 3 0 7.31s
✅ SignInWebSheetViewModelTests 31 31 0 307ms
✅ SignOutCacheClearingTests 3 3 0 8ms
✅ SingletonResetRegistryTests 5 5 0 134ms
✅ StatsViewModelTests 10 10 0 270ms
✅ StatusAnnouncementTests 22 22 0 168ms
✅ StopPositionSaveTests 2 2 0 13ms
✅ StoreTests 5 5 0 36ms
✅ StreamingReaderPresentationContractTests 1 1 0 11ms
✅ StreamingReaderProgressStoreTests 7 7 0 71ms
✅ StreamingReaderViewControllerScrollRestoreTests 12 12 0 1.61s
✅ StreamingReaderViewModelTests 9 9 0 118ms
✅ StringExtensionTests 8 8 0 61ms
✅ StringExtensionsTests 3 3 0 39ms
✅ StringHTMLEntitiesTests 7 7 0 48ms
✅ StringNYPLAdditionsTests 4 4 0 17ms
✅ String_NYPLAdditionsTests 4 4 0 91ms
✅ SupportSectionDecisionTests 5 5 0 409ms
✅ SyncConflictResolutionTests 3 3 0 47ms
✅ SyncDeletionGuardTests 5 5 0 130ms
✅ SyncDeletionRatioTests 6 6 0 23ms
✅ SyncPermissionTests 5 5 0 219ms
✅ TPPAccountAuthStateEnumTests 5 5 0 38ms
✅ TPPAccountListDataSourceTests 3 3 0 8ms
✅ TPPAdobeActivationSkipTests 6 6 0 656ms
✅ TPPAgeCheckCompletionTests 5 5 0 559ms
✅ TPPAgeCheckIsValidTests 5 5 0 25ms
✅ TPPAgeCheckStateMachineTests 4 4 0 515ms
✅ TPPAgeCheckTests 6 6 0 1.58s
✅ TPPAgeCheckVerifyDecisionTests 5 5 0 504ms
✅ TPPAlertUtilsTests 45 45 0 838ms
✅ TPPAnnotationsHermeticTests 15 15 0 143ms
✅ TPPAnnotationsOverrideTests 4 4 0 271ms
✅ TPPAnnotationsTests 29 29 0 5.80s
✅ TPPAnnouncementManagerTests 3 3 0 31ms
✅ TPPAuthDocumentContractTests 3 3 0 28ms
✅ TPPBackgroundExecutorTests 3 3 0 27ms
✅ TPPBadgeImageGapTests 2 2 0 17ms
✅ TPPBaseReaderViewControllerInitialLocationTests 5 5 0 41ms
✅ TPPBasicAuthTests 11 11 0 89ms
✅ TPPBookAccessibilityLabelTests 8 8 0 39ms
✅ TPPBookAuthorCoverageTests 3 3 0 8ms
✅ TPPBookAuthorTests 6 6 0 86ms
✅ TPPBookBearerTokenTests 9 8 0 133ms
✅ TPPBookButtonsStateTests 7 7 0 26ms
✅ TPPBookContentMetadataFilesHelperTests 9 9 0 33ms
✅ TPPBookContentTypeConverterStreamingHTMLTests 2 2 0 120ms
✅ TPPBookContentTypeConverterTests 4 4 0 16ms
✅ TPPBookContentTypeExtendedTests 4 4 0 48ms
✅ TPPBookContentTypeTests 14 14 0 52ms
✅ TPPBookCoverRegistryTests 14 14 0 689ms
✅ TPPBookCreationTests 7 7 0 82ms
✅ TPPBookExtensionsTests 21 21 0 104ms
✅ TPPBookIsDRMProtectedTests 9 9 0 32ms
✅ TPPBookLocationCoverageTests 7 7 0 51ms
✅ TPPBookLocationEdgeCaseTests 27 27 0 75ms
✅ TPPBookLocationKeyTests 3 3 0 20ms
✅ TPPBookLocationTests 11 11 0 56ms
✅ TPPBookModelGapTests 4 4 0 33ms
✅ TPPBookRegistryAsyncReadinessTests 3 3 0 552ms
✅ TPPBookRegistryAtomicWriteTests 7 7 0 1.14s
✅ TPPBookRegistryBookRetrievalTests 7 7 0 162ms
✅ TPPBookRegistryBookmarkTests 7 7 0 158ms
✅ TPPBookRegistryCorruptedDataTests 5 5 0 34ms
✅ TPPBookRegistryDataTests 4 4 0 29ms
✅ TPPBookRegistryDependencyTests 4 4 0 73ms
✅ TPPBookRegistryFulfillmentIdTests 4 4 0 56ms
✅ TPPBookRegistryLargeCorpusTests 5 5 0 2m 24s
✅ TPPBookRegistryLoadReentrancyTests 2 2 0 32ms
✅ TPPBookRegistryLocationTests 4 4 0 79ms
✅ TPPBookRegistryMigrationTests 16 16 0 1.83s
✅ TPPBookRegistryPersistenceTests 10 10 0 1.93s
✅ TPPBookRegistryProcessingTests 2 2 0 21ms
✅ TPPBookRegistryPublisherTests 6 6 0 987ms
✅ TPPBookRegistryRecordPersistenceTests 3 3 0 37ms
✅ TPPBookRegistryRecordTests 10 10 0 42ms
✅ TPPBookRegistryStateManagementTests 11 11 0 18.55s
✅ TPPBookRegistryThreadSafetyTests 3 3 0 653ms
✅ TPPBookRegistryUpdateAndRemoveTests 1 1 0 27ms
✅ TPPBookRequiresAdobeDRMTests 6 6 0 31ms
✅ TPPBookSerializationTests 13 13 0 111ms
✅ TPPBookStateInitializationTests 4 4 0 13ms
✅ TPPBookStateTests 4 4 0 32ms
✅ TPPBookTests 93 93 0 428ms
✅ TPPBookmarkDeletionLogTests 11 11 0 172ms
✅ TPPBookmarkFactoryInitTests 2 2 0 11ms
✅ TPPBookmarkFactoryServerAnnotationEdgeCaseTests 5 5 0 58ms
✅ TPPBookmarkFactoryTests 15 15 0 84ms
✅ TPPBookmarkR3ConversionTests 5 5 0 24ms
✅ TPPBookmarkR3LocationTests 13 13 0 30ms
✅ TPPBookmarkSpecTests 1 1 0 7ms
✅ TPPCachingTests 3 3 0 21ms
✅ TPPCapturedCredentialsTests 5 5 0 5.74s
✅ TPPConfigurationTests 22 22 0 67ms
✅ TPPContentTypeTests 9 9 0 32ms
✅ TPPCredentialConcurrencyTests 3 3 0 14ms
✅ TPPCredentialIsolationE2ETests 5 0 0 180ms
✅ TPPCredentialPersistenceTests 6 6 0 588ms
✅ TPPCredentialSnapshotCoherenceTests 3 0 0 2.36s
✅ TPPCredentialSnapshotTests 8 8 0 22ms
✅ TPPCredentialsCoverageTests 9 9 0 39ms
✅ TPPCredentialsTests 26 26 0 161ms
✅ TPPCrossLibrarySignOutTests 6 6 0 995ms
✅ TPPDRMFailureCredentialPreservationTests 4 4 0 445ms
✅ TPPErrorLoggerTests 27 27 0 436ms
✅ TPPIdleSignOutRegressionTests 13 13 0 1.31s
✅ TPPJWKConversionTest 1 1 0 23ms
✅ TPPKeychainManagerTests 5 5 0 34ms
✅ TPPLastReadPositionPosterTests 13 13 0 425ms
✅ TPPLastReadPositionSynchronizerIntegrationTests 5 5 0 44ms
✅ TPPLastReadPositionSynchronizerTests 23 23 0 112ms
✅ TPPLastReadPositionSynchronizer_BehaviorDocumentationTests 5 5 0 29ms
✅ TPPLastReadPositionSynchronizer_BookLocationTests 9 9 0 29ms
✅ TPPLastReadPositionSynchronizer_ConcurrencyTests 3 3 0 23ms
✅ TPPLastReadPositionSynchronizer_ReadiumBookmarkTests 9 9 0 26ms
✅ TPPLastReadPositionSynchronizer_SyncLogicTests 10 10 0 44ms
✅ TPPLastReadPositionSynchronizer_WriterDelegationTests 4 4 0 22ms
✅ TPPLoginNoActivationTests 3 3 0 514ms
✅ TPPMainThreadCheckerTests 4 4 0 65ms
✅ TPPMigrationManagerTests 15 15 0 43ms
✅ TPPNetworkExecutorAPITests 14 14 0 151ms
✅ TPPNetworkExecutorStubbedTests 17 17 0 365ms
✅ TPPNetworkExecutorTests 3 3 0 14ms
✅ TPPNetworkResponderAuthCoordinatorTests 5 5 0 28ms
✅ TPPNetworkResponderTests 12 12 0 218ms
✅ TPPOPDSAcquisitionPathTests 5 5 0 47ms
✅ TPPOPDSEntryTests 5 5 0 36ms
✅ TPPOPDSFeedTests 3 3 0 431ms
✅ TPPOPDSGroupSwiftTests 3 3 0 13ms
✅ TPPOPDSLinkTests 7 7 0 46ms
✅ TPPOpenSearchDescriptionExpandedTests 10 10 0 39ms
✅ TPPOpenSearchDescriptionTests 1 1 0 5ms
✅ TPPPDFDocumentMetadataTests 15 15 0 179ms
✅ TPPPDFDocumentTests 8 8 0 20ms
✅ TPPPDFLocationCoverageTests 7 7 0 42ms
✅ TPPPDFLocationTests 10 10 0 90ms
✅ TPPPDFPageBookmarkTests 9 9 0 53ms
✅ TPPPDFPageTests 5 5 0 24ms
✅ TPPPDFReaderModeTests 6 6 0 59ms
✅ TPPPerAccountIsolationTests 8 0 0 255ms
✅ TPPPreferredAuthSelectionTests 8 8 0 1.12s
✅ TPPProblemDocumentCacheManagerTests 12 12 0 91ms
✅ TPPProblemDocumentTests 21 21 0 104ms
✅ TPPReaderAppearanceTests 4 4 0 13ms
✅ TPPReaderBookmarksBusinessLogicTests 12 12 0 1.44s
✅ TPPReaderBookmarksReadinessTests 2 2 0 206ms
✅ TPPReaderFontTests 4 4 0 24ms
✅ TPPReaderPreferencesLoadTests 3 3 0 26ms
✅ TPPReaderSettingsTests 28 28 0 288ms
✅ TPPReaderTOCBusinessLogicTests 15 15 0 3.24s
✅ TPPReaderTOCFlattenTests 2 2 0 1.03s
✅ TPPReadiumBookmarkLocationMatchingTests 5 5 0 40ms
✅ TPPReadiumBookmarkTests 21 21 0 2.35s
✅ TPPReauthenticatorMockTests 2 2 0 26ms
✅ TPPReauthenticatorTests 4 4 0 26ms
✅ TPPReturnPromptHelperTests 5 5 0 28ms
✅ TPPSAMLCookieExpirationTests 7 7 0 31ms
✅ TPPSAMLFlowTests 10 10 0 53ms
✅ TPPSAMLReauthFlowTests 2 2 0 249ms
✅ TPPSAMLRegressionTests 4 4 0 518ms
✅ TPPSAMLSignInTests 26 26 0 3.80s
✅ TPPSAMLStateIsolationTests 4 4 0 210ms
✅ TPPSAMLStateMachineTests 6 6 0 569ms
✅ TPPSettingsTests 6 6 0 3.34s
✅ TPPSignInAdobeSkipTests 14 14 0 1.70s
✅ TPPSignInAuthStateTransitionTests 3 3 0 297ms
✅ TPPSignInBusinessLogicExtendedTests 58 58 0 9.48s
✅ TPPSignInBusinessLogicOAuthTests 11 11 0 1.18s
✅ TPPSignInBusinessLogicSignOutTests 11 11 0 1.46s
✅ TPPSignInBusinessLogicStateMachineTests 9 9 0 955ms
✅ TPPSignInBusinessLogicTests 18 18 0 2.48s
✅ TPPSignInBusinessLogicTokenFlowTests 3 3 0 346ms
✅ TPPSignInBusinessLogicValidationCallbackOrderTests 2 2 0 301ms
✅ TPPSignInErrorHandlingTests 2 2 0 170ms
✅ TPPSignInProfileDocEdgeCaseTests 3 3 0 410ms
✅ TPPSignedInStateProviderTests 3 3 0 12ms
✅ TPPUserAccountAuthStateTests 6 6 0 22ms
✅ TPPUserAccountGapTests 4 4 0 12ms
✅ TPPUserAccountIsolationLintTests 3 3 0 797ms
✅ TPPUserAccountTestFactoryTests 7 0 0 83ms
✅ TPPUserFriendlyErrorTests 11 11 0 59ms
✅ TPPUserNotificationsTests 10 10 0 154ms
✅ TPPXMLSwiftTests 16 16 0 110ms
✅ TPPXMLTests 3 3 0 28ms
✅ TearDownRequiredLintTests 5 5 0 1.90s
✅ TestAppContainerFactoryTests 5 5 0 92ms
✅ TimeEntryTests 3 3 0 15ms
❌ TokenRefreshAndRetryQueueTests 11 10 1 9.29s
✅ TokenRefreshIntegrationTests 2 2 0 254ms
✅ TokenRefreshInterceptorAuthCoordinatorTests 8 8 0 4.53s
✅ TokenRefreshInterceptorTests 24 24 0 6.73s
✅ TokenRefreshOnForegroundTests 10 10 0 2.70s
✅ TokenRefreshTests 25 25 0 102ms
✅ TokenRequestCredentialGuardTests 13 13 0 173ms
✅ TokenRequestTests 11 11 0 128ms
✅ TokenResponseTests 21 21 0 59ms
✅ TypographyPresetTests 21 21 0 669ms
✅ TypographyServiceTests 31 31 0 1.30s
✅ TypographySettingsViewModelTests 27 27 0 1.15s
✅ UIAlertCACommitGuardTests 8 8 0 252ms
✅ UIColor_NYPLAdditionsTests 1 1 0 3ms
✅ URLBackupExclusionTests 3 3 0 18ms
✅ URLExtensionTests 16 16 0 228ms
✅ URLExtensionsTests 6 6 0 25ms
✅ URLRequestExtensionsCoverageTests 3 3 0 8ms
✅ URLRequestExtensionsTests 11 11 0 60ms
✅ URLRequestNYPLAdditionsTests 11 11 0 87ms
✅ URLRequest_NYPLTests 1 1 0 4ms
✅ URLResponseAuthenticationTests 10 10 0 30ms
✅ URLResponseNYPLTests 14 14 0 70ms
✅ URLSessionCredentialStorageTests 3 3 0 49ms
✅ URLSessionStubbingResetTests 2 2 0 12ms
✅ URLTypeTests 2 2 0 8ms
✅ URLValidationTests 5 5 0 10ms
✅ UnifiedOPDSServiceStateMachineTests 2 2 0 501ms
✅ UserAccountPublisherAuthStateTests 5 5 0 92ms
✅ UserAccountPublisherTests 14 14 0 1.03s
✅ UserAccountValidationTests 11 11 0 1.27s
✅ UserDefaultsIsolationLintTests 2 2 0 764ms
✅ UserProfileDocumentTests 7 7 0 58ms
✅ UserRetryTrackerTests 10 10 0 195ms
✅ XCTestCase_testUserDefaultsTests 3 3 0 44ms
✅ iPadOnMacRMSDKGuardTests 1 1 0 6ms
Failed Tests (click to expand)
TokenRefreshAndRetryQueueTests.First Run

📊 Testing Coverage Breakdown

Unit Test Line Coverage (testable surfaces): 47.4%

Total coverage incl. UI/lifecycle: 45.6% (18 files excluded from testable denominator — see scripts/coverage-exclude.json)

Target Lines Covered
Palace.app 45.6%

Why two coverage numbers? Testable coverage subtracts files that can't be exercised from xcodebuild — SwiftUI views, UIKit VCs, lifecycle (see scripts/coverage-exclude.json) — so raising it means more testable logic is tested, not that we shipped less UI. Total coverage is kept for continuity. The excluded paths are covered by simdrive E2E journeys (see chaos-replay-on-pr.yml).

📈 Trends

Test count change: +5

⚠️ New Failures
TokenRefreshAndRetryQueueTests.First Run

🔗 Interactive HTML Report | CI Run Details

📦 Downloadable Artifacts
Artifact Description
test-report 📄 Markdown + HTML reports
test-data 📊 JSON data for tooling
test-results 🔍 Full xcresult (open in Xcode)

mauricecarrier7 added a commit that referenced this pull request Jun 9, 2026
…007/F-003 tests

CI build-and-test on #1052 failed the static isolation lints (not a flake):
- AudiobookPositionRestoreTests used a bare `AccountsManager()` (via a
  `makeIsolatedAccountsManager()` helper) — the exact polluter the lint guards
  (bare init spins a background loadCatalogs Task that outlives the test).
  Fixed: build the manager through the whitelisted `makeTestAppContainer`
  (pins deferInitialLoadCatalogsForTesting, so no background work) and rename
  the helper to `makeIsolatedManager()` so its call sites don't trip the
  substring `AccountsManager(` matcher.
- BookRegistrySyncTests' 3 `AppContainer.production().accountsManager
  .userAccount(for:)` credential writes are legitimate: sync() checks
  hasCredentials() via sharedAccount→production keychain-backed userAccount
  (only currentAccount STATE is injected). Marked `// MIGRATED-DEFERRED:` per
  the lint's documented escape for "production resolution IS the test contract".

Verified: AccountsManagerIsolationLintTests + AppContainerIsolationLintTests +
AudiobookPositionRestoreTests + BookRegistrySyncTests = 42 tests, 0 failures.

**Scope:** test-only; no production change. Resolves the #1052 CI red.
@mauricecarrier7 mauricecarrier7 self-assigned this Jun 9, 2026
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
…between tests (#1056)

`AccountsManager.deferInitialLoadCatalogsForTesting` is a process-wide mutable
static flag gating whether `AccountsManager.init` spawns its background
`loadCatalogs` Task. The test-safe value is `true` (no background work);
`PalaceTestSetup.bootstrap()` pins it `true` at bundle load. Tests that need the
background load opt IN by setting it `false` in their own setUp.

Two sites left it `false` after running, leaking the unsafe value to the next
test class — which then constructs a real `AccountsManager`, spawning the
1100+-library registry crawl that outlives the test and pollutes whatever runs
next:
  - `AppContainer._resetForTesting()` — runs after EVERY test via the
    singleton-reset observer; its final line set the flag false.
  - `AppContainerResetTests.tearDown()` — explicitly set it false "for
    production semantics."

Both now leave the flag at the test-safe `true`. This is the root cause behind
recurring CI flakes that blocked PRs #1052/#1053/#1054 (none of whose own diffs
were at fault):
  - AccountsManagerCancellationTests.testCancelBackgroundWork_onOptOutInstance
    _isSafeNoOp — opt-out handle non-nil (failed all 3 iterations)
  - CatalogCacheKeyAndIsolationTests — layout-engine-off-main crash
  - BookReturnCleverReauthTests — crash → ** TEST FAILED ** with 0 reported
    failures
  - TokenRefreshOnForeground / TokenRefreshAndRetryQueue — token/network bleed

Regression: AppContainerResetTests.testResetForTesting_disablesBackgroundLoad
Catalogs now asserts the flag is `true` post-reset (was asserting false) — the
mutation that reintroduces the leak fails it.

No production runtime change: the flag is only ever non-default inside an XCTest
process (initializer keys off XCTestConfigurationFilePath); `_resetForTesting()`
already early-returns outside XCTest.

Verified: AppContainerResetTests + AccountsManagerCancellationTests +
CatalogCacheKeyAndIsolationTests + TokenRefreshOnForegroundTests +
TokenRefreshAndRetryQueueTests + BookReturnCleverReauthTests run together →
41 tests, 0 failures, ** TEST SUCCEEDED **.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
git invokes pre-push hooks with GIT_DIR/GIT_WORK_TREE/GIT_INDEX_FILE
exported. xcodebuild's SwiftPM resolution shells out to git internally, and
an inherited GIT_WORK_TREE makes local-package paths resolve to "/", failing
with: "the package manifest at '/Package.swift' doesn't exist". This blocked
EVERY push that touches a Palace/*.swift file from a linked git worktree (and
is latent on the main checkout under some git versions) — the same xcodebuild
command run from a plain shell succeeds.

Fix: wrap the gate's xcodebuild in `env -u GIT_DIR -u GIT_WORK_TREE
-u GIT_INDEX_FILE -u GIT_PREFIX -u GIT_EXEC_PATH`. Also scope a per-checkout
DerivedData/SourcePackages dir for linked-worktree pushes so they don't
collide with the main checkout's warm cache.

Reproduced: `-resolvePackageDependencies` succeeds with the git env cleared
and fails (/Package.swift) with GIT_DIR+GIT_WORK_TREE set. Verified end-to-end:
PR #1052's worktree push now passes the gate green (`PASS — 4 class(es) green`)
instead of the false /Package.swift failure.

**Scope:** single hook script. **Not done:** a scripts/tests/ fixture asserting
the env-clear (follow-up per green-board contract #4 — tooling under CI).
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
…007/F-003 tests

CI build-and-test on #1052 failed the static isolation lints (not a flake):
- AudiobookPositionRestoreTests used a bare `AccountsManager()` (via a
  `makeIsolatedAccountsManager()` helper) — the exact polluter the lint guards
  (bare init spins a background loadCatalogs Task that outlives the test).
  Fixed: build the manager through the whitelisted `makeTestAppContainer`
  (pins deferInitialLoadCatalogsForTesting, so no background work) and rename
  the helper to `makeIsolatedManager()` so its call sites don't trip the
  substring `AccountsManager(` matcher.
- BookRegistrySyncTests' 3 `AppContainer.production().accountsManager
  .userAccount(for:)` credential writes are legitimate: sync() checks
  hasCredentials() via sharedAccount→production keychain-backed userAccount
  (only currentAccount STATE is injected). Marked `// MIGRATED-DEFERRED:` per
  the lint's documented escape for "production resolution IS the test contract".

Verified: AccountsManagerIsolationLintTests + AppContainerIsolationLintTests +
AudiobookPositionRestoreTests + BookRegistrySyncTests = 42 tests, 0 failures.

**Scope:** test-only; no production change. Resolves the #1052 CI red.
@mauricecarrier7 mauricecarrier7 force-pushed the fix/pp4542-regression-test-coverage branch from bc42c77 to 3242868 Compare June 10, 2026 14:37
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
git invokes pre-push hooks with GIT_DIR/GIT_WORK_TREE/GIT_INDEX_FILE
exported. xcodebuild's SwiftPM resolution shells out to git internally, and
an inherited GIT_WORK_TREE makes local-package paths resolve to "/", failing
with: "the package manifest at '/Package.swift' doesn't exist". This blocked
EVERY push that touches a Palace/*.swift file from a linked git worktree (and
is latent on the main checkout under some git versions) — the same xcodebuild
command run from a plain shell succeeds.

Fix: wrap the gate's xcodebuild in `env -u GIT_DIR -u GIT_WORK_TREE
-u GIT_INDEX_FILE -u GIT_PREFIX -u GIT_EXEC_PATH`. Also scope a per-checkout
DerivedData/SourcePackages dir for linked-worktree pushes so they don't
collide with the main checkout's warm cache.

Reproduced: `-resolvePackageDependencies` succeeds with the git env cleared
and fails (/Package.swift) with GIT_DIR+GIT_WORK_TREE set. Verified end-to-end:
PR #1052's worktree push now passes the gate green (`PASS — 4 class(es) green`)
instead of the false /Package.swift failure.

**Scope:** single hook script. **Not done:** a scripts/tests/ fixture asserting
the env-clear (follow-up per green-board contract #4 — tooling under CI).
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
…007/F-003 tests

CI build-and-test on #1052 failed the static isolation lints (not a flake):
- AudiobookPositionRestoreTests used a bare `AccountsManager()` (via a
  `makeIsolatedAccountsManager()` helper) — the exact polluter the lint guards
  (bare init spins a background loadCatalogs Task that outlives the test).
  Fixed: build the manager through the whitelisted `makeTestAppContainer`
  (pins deferInitialLoadCatalogsForTesting, so no background work) and rename
  the helper to `makeIsolatedManager()` so its call sites don't trip the
  substring `AccountsManager(` matcher.
- BookRegistrySyncTests' 3 `AppContainer.production().accountsManager
  .userAccount(for:)` credential writes are legitimate: sync() checks
  hasCredentials() via sharedAccount→production keychain-backed userAccount
  (only currentAccount STATE is injected). Marked `// MIGRATED-DEFERRED:` per
  the lint's documented escape for "production resolution IS the test contract".

Verified: AccountsManagerIsolationLintTests + AppContainerIsolationLintTests +
AudiobookPositionRestoreTests + BookRegistrySyncTests = 42 tests, 0 failures.

**Scope:** test-only; no production change. Resolves the #1052 CI red.
@mauricecarrier7 mauricecarrier7 force-pushed the fix/pp4542-regression-test-coverage branch from 3242868 to 0a184a9 Compare June 10, 2026 16:39
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
…007/F-003 tests

CI build-and-test on #1052 failed the static isolation lints (not a flake):
- AudiobookPositionRestoreTests used a bare `AccountsManager()` (via a
  `makeIsolatedAccountsManager()` helper) — the exact polluter the lint guards
  (bare init spins a background loadCatalogs Task that outlives the test).
  Fixed: build the manager through the whitelisted `makeTestAppContainer`
  (pins deferInitialLoadCatalogsForTesting, so no background work) and rename
  the helper to `makeIsolatedManager()` so its call sites don't trip the
  substring `AccountsManager(` matcher.
- BookRegistrySyncTests' 3 `AppContainer.production().accountsManager
  .userAccount(for:)` credential writes are legitimate: sync() checks
  hasCredentials() via sharedAccount→production keychain-backed userAccount
  (only currentAccount STATE is injected). Marked `// MIGRATED-DEFERRED:` per
  the lint's documented escape for "production resolution IS the test contract".

Verified: AccountsManagerIsolationLintTests + AppContainerIsolationLintTests +
AudiobookPositionRestoreTests + BookRegistrySyncTests = 42 tests, 0 failures.

**Scope:** test-only; no production change. Resolves the #1052 CI red.
@mauricecarrier7 mauricecarrier7 force-pushed the fix/pp4542-regression-test-coverage branch from 0a184a9 to 82fc49c Compare June 10, 2026 17:15
mauricecarrier7 and others added 6 commits June 10, 2026 15:21
…ve XCTSkipIf dodge (F-003 / PP-4542)

The PP-4407 awaitReady() migration moved BookRegistrySync.sync()'s loansUrl
read out of the synchronous guard and into the post-awaitReady() Task. The
old `guard let loansUrl = currentAccount.loansUrl else { return }` was a clean
synchronous no-op; the new code reaches setState(.loaded) + completion(nil,false)
for the "current account present but no loansUrl" case — either synchronously
(no stored credentials) or after awaitReady() resolves to AccountDetails with a
nil loansUrl (anonymous library).

Two tests were band-aided with `try XCTSkipIf(currentAccount?.loansUrl != nil)`,
so they false-greened on a signed-in CI simulator and only ran (and would only
catch the regression) in a clean environment. That is illusory coverage on the
registry-sync critical path (TPPBookRegistry is the single source of truth for
checkouts/holds/reading position).

This replaces the dodge with deterministic, host-independent behavior tests
that inject a fresh-UUID fixture account (so the production-stack credentials
lookup — TPPUserAccount.sharedAccount(libraryUUID:) → production manager's
userAccount(for:) — returns a never-signed-in instance regardless of host
sign-in state):

- test_sync_withCurrentAccountButNoCredentials_resolvesToLoadedSynchronously
  Asserts the NEW synchronous credentials-gate contract: setState exactly
  [.loaded], completion(nil,false), syncUrl stays nil. No keychain needed.
- test_sync_whenAlreadySyncing_returnsBeforeSettingSyncingState
  Drives the re-entrancy guard, which is only REACHABLE once credentials exist
  (it sits after the credentials gate). Writes credentials to the exact
  production-manager instance sync() reads, drives awaitReady to a terminal
  detailsLoaded(nil loansUrl), and asserts currentState == .syncing
  short-circuits before setState. Keychain-gated (environment-capability guard,
  not a host-state dodge).
- test_sync_whenNotSyncing_withCredentialsAndNoLoansUrl_resolvesToLoaded
  Contrast: SAME credentialed/no-loansUrl fixture but currentState == .loaded
  proceeds into the Task and resolves to .loaded — proving the .syncing guard
  (not the credentials) is what suppresses setState.

Each assertion would fail under a real regression of the guard logic. No
production code changed — the new transient setState behavior is not
user-harmful (loaded → loaded for an account that was already loaded), so
option (a) honest-test was correct over option (b) production change.

**Scope:** test-only. PalaceTests/Book/BookRegistrySyncTests.swift.
Verified: -only-testing:PalaceTests/BookRegistrySyncTests → ** TEST SUCCEEDED **,
all 3 new tests pass (not skipped). check-test-name-vs-body.py exit 0.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds discriminating, behavior-asserting tests for two 3.2.0-regression
test-quality findings surfaced by diff-only mutation testing. Test-only
change — no production code touched.

F-006 DownloadAuthRetryHandler (foreign-host 401 guard, lines 234/240):
  - testHandle_401_foreignHost_browserSAML_shortCircuitsReturnsFalse_noReauth
  - testHandle_401_accountHost_browserSAML_guardDoesNotFire_drivesSAMLRetry
  - testHandle_403_foreignHost_noCredentials_guardDoesNotIntercept_signInStillFires
  Kills :234 ==->!= and :240 return false->true. diff-only kill rate 100% (3/3).

F-008 SAML/browser-auth branch detection:
  - BookReturnService :476 isBrowserBased==true (markCredentialsStale gate):
    testReturnBook_SAMLBrowserAuth_invalidCredentials_marksCredentialsStaleBeforeReauth
    + basicAuth negative control. diff-only 100% (2/2), :476 KILLED.
  - TokenRefreshInterceptor :166 + :216 isSaml==true (SAML-vs-browser legacy
    dispatch): two tests asserting .SAMLStarted+startDownload+no-reauth vs
    .downloadNeeded+reauth. Both :166 and :216 KILLED.
  - BorrowOperation :636 needsBrowserReauth (isBrowserBased==true && hasCreds):
    testBorrow_SAMLBrowserAuth_withCredentials_routesToReauthModalNotAlert.
    :636 ==->!= and &&->|| both KILLED (file 33%->63.6%).

**Scope:** test-only; 4 PalaceTests files; +417 LOC.
**Not done (deliberate, anti-fluff per CLAUDE.md):** BorrowOperation :685/:677
(isSaml==true selecting authLabel/reason) are cosmetic — authLabel is
log-only and reason collapses to the same AuthCoordinator.routeName "modal"
route for a SAML mechanism, so no observable downstream difference. :581/:592
are logically dead: the isAuthError closure unconditionally returns true at
:592, so :581 flips change nothing observable. Killing these would require
fluff or a production-logic change out of F-008 scope.
**Deferred:** none.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…n mutant coverage

PR #1028 added the stale-position-on-reborrow hardening in
AudiobookSessionManager (validationFailure / fallback-to-most-recent
bookmark). The changed lines shipped with a 0% diff-only mutation kill
rate — the position-validation and candidate-selection logic on the
audiobook-playback critical path was unasserted.

New behavior tests at the production seams pin the real decisions with
constructed TOC + registry + account fixtures (no live Audiobook/player
graph, so the toolkit's fragility doesn't leak into the suite):

  - candidate recency ordering: a reverse sort ('<') now returns the
    OLDEST bookmark and fails testSelectMostRecentValidBookmark_*
  - TOC track-key match: in-manifest vs foreign key asserted both ways
  - validationFailure==nil filter inside selectMostRecentValidBookmark:
    a cap-exceeding (valid-key, reconstructs) candidate must be dropped
    and the valid older one selected — kills the filter-inversion mutant
  - isValidPosition valid/invalid both sides
  - isUserAuthenticated auth-doc-load-failure -> not-authenticated

To make the candidate filter+sort testable without a live Audiobook,
extracted the pure selection step into selectMostRecentValidBookmark
(from: [TPPBookLocation], in: AudiobookTableOfContents); the four seam
methods are now `internal` (not `private`) so @testable tests reach
them — mirrors the existing static-policy-mirror pattern in this file.

Mutation (diff-only vs origin/release/3.1.0, full changed-line coverage
across AudiobookPositionRestoreTests + the existing
AudiobookNetworkValidationTests + AudiobookLoadFailureSAMLReauthTests):
0% -> 88.9% (8/9 killed). The lone survivor is line 1324 '>' -> '>='
on candidates.sorted: with distinct ISO8601 timestamps '>' and '>='
produce identical output, and on a tie either bookmark is equally
"most recent" — killing it would require asserting an arbitrary Swift
sort-stability detail with no behavioral contract, which is banned
fluff. Documented as an equivalent mutant, not covered.

**Scope:** Test-coverage fix on a critical path (audiobook position
restore). Production change is visibility-only + one pure-function
extraction (no behavior change): 4 methods private->internal, plus
fallbackToMostRecentValidBookmark delegating to the extracted
selectMostRecentValidBookmark. No call-site, signature, or control-flow
change to shipping behavior.
**Not done:** the 1324 '>'->'>=' tie-break mutant (equivalent — see above).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…4542)

XCTestConfigurationFilePath / environment["XCTest..."] / NSClassFromString("XCTest")
guards are unkillable by design (suite always runs under XCTest), so counting
them as mutants deflates kill rate with no real coverage signal. Mirrors the
existing _LOG_LINE_PATTERN skip. TPPReauthenticator.swift:66 was the canonical
false-0%: now correctly reports 0 mutable points on the changed line.

**Scope:** tooling only (scripts/palace_mutate.py); no production or test code.
Verified: diff-only enumeration on TPPReauthenticator drops 1->0 mutants.
…hangeset

ForgeOS changeset: cs_7e7ab728
Reviewed-by (architect): rev_39f29990 APPROVED (extraction behavior-preserving; internal-not-public visibility; no behavior change)
Reviewed-by (qa_test): rev_7114cb1a APPROVED (XCTSkipIf dodge removed; mutation kills credible; deliberate skips legitimate)

Gates passed: review, testing, release (proj_87884c17).
Critical-path file touched: Palace/Audiobooks/AudiobookSessionManager.swift.

**Scope:** governance record only (empty commit). Non-blocking follow-ups:
F-009 (BookReturnService:235 task! force-unwrap, pre-existing, separate changeset);
QA warning on fixed-poll async test loops.
…007/F-003 tests

CI build-and-test on #1052 failed the static isolation lints (not a flake):
- AudiobookPositionRestoreTests used a bare `AccountsManager()` (via a
  `makeIsolatedAccountsManager()` helper) — the exact polluter the lint guards
  (bare init spins a background loadCatalogs Task that outlives the test).
  Fixed: build the manager through the whitelisted `makeTestAppContainer`
  (pins deferInitialLoadCatalogsForTesting, so no background work) and rename
  the helper to `makeIsolatedManager()` so its call sites don't trip the
  substring `AccountsManager(` matcher.
- BookRegistrySyncTests' 3 `AppContainer.production().accountsManager
  .userAccount(for:)` credential writes are legitimate: sync() checks
  hasCredentials() via sharedAccount→production keychain-backed userAccount
  (only currentAccount STATE is injected). Marked `// MIGRATED-DEFERRED:` per
  the lint's documented escape for "production resolution IS the test contract".

Verified: AccountsManagerIsolationLintTests + AppContainerIsolationLintTests +
AudiobookPositionRestoreTests + BookRegistrySyncTests = 42 tests, 0 failures.

**Scope:** test-only; no production change. Resolves the #1052 CI red.
mauricecarrier7 added a commit that referenced this pull request Jun 10, 2026
git invokes pre-push hooks with GIT_DIR/GIT_WORK_TREE/GIT_INDEX_FILE
exported. xcodebuild's SwiftPM resolution shells out to git internally, and
an inherited GIT_WORK_TREE makes local-package paths resolve to "/", failing
with: "the package manifest at '/Package.swift' doesn't exist". This blocked
EVERY push that touches a Palace/*.swift file from a linked git worktree (and
is latent on the main checkout under some git versions) — the same xcodebuild
command run from a plain shell succeeds.

Fix: wrap the gate's xcodebuild in `env -u GIT_DIR -u GIT_WORK_TREE
-u GIT_INDEX_FILE -u GIT_PREFIX -u GIT_EXEC_PATH`. Also scope a per-checkout
DerivedData/SourcePackages dir for linked-worktree pushes so they don't
collide with the main checkout's warm cache.

Reproduced: `-resolvePackageDependencies` succeeds with the git env cleared
and fails (/Package.swift) with GIT_DIR+GIT_WORK_TREE set. Verified end-to-end:
PR #1052's worktree push now passes the gate green (`PASS — 4 class(es) green`)
instead of the false /Package.swift failure.

**Scope:** single hook script. **Not done:** a scripts/tests/ fixture asserting
the env-clear (follow-up per green-board contract #4 — tooling under CI).
@mauricecarrier7 mauricecarrier7 force-pushed the fix/pp4542-regression-test-coverage branch from 82fc49c to 3dec22d Compare June 10, 2026 19:24
@mauricecarrier7 mauricecarrier7 merged commit c018625 into develop Jun 10, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant